package org.tc.service;

import org.tc.bean.User;
import org.tc.exception.CustomException;

/**
 * Created by zxd on 2018/1/31.
 */
public interface UserService {
    /**
     * 注册
     * @param user
     */
    public void register(User user) throws CustomException;

    /**
     * 用户名密码登录
     * @param username
     * @param password
     * @return
     */
    public String login(String username,String password) throws CustomException;


    /**
     * 根据token查询用户信息
     * @param token
     * @return
     */
    public User queryUserByToken(String token);

    public String loginByPhone(String phoneNumber, String smscode) throws CustomException;

    public Boolean check(String param, Integer type);

}
